gusucode.com > ASP+ACCESS在线手机销售系统(论文+源代码+答辩PPT) > ASP+ACCESS在线手机销售系统(论文+源代码+答辩PPT)\9)ASP 在线手机销售系统\HandsetPro\handset\admin\proDel.asp
<!-- #include file = "include/sysbase.asp" --> <% dim nID dim strSQL '如果参数非法,防止传入类似 manuDel.asp?id=3 or 1=1 if not IsNumeric(nID) then Response.Write "<script language = Javascript>" Response.Write "alert('您输入的数据不合法!');" Response.Write "window.history.go(-1);" Response.Write "</script>" Response.End end if nID = RealString(Request.QueryString("id")) strSQL = "DELETE FROM Product WHERE id = " & nID conn.Execute ( strSQL ) %> <script language = Javascript> <!-- alert("删除完毕"); this.document.location = "<%=Session("adminOldUrl")%>"; --> </script>